package org.dromara.xyyw.domain.bo;

import org.dromara.xyyw.domain.XyywCouponUsageRecord;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;
import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;
import java.io.Serial;
import java.io.Serializable;

/**
 * 优惠券使用记录业务对象 xyyw_coupon_usage_record
 *
 * @author yf
 * @date 2024-05-29
 */
@Data
@AutoMapper(target = XyywCouponUsageRecord.class, reverseConvertGenerate = false)
public class XyywCouponUsageRecordBo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 使用记录ID
     */
    @NotNull(message = "使用记录ID不能为空", groups = {EditGroup.class})
    private Integer usageId;

    /**
     * 优惠券ID
     */
    @NotNull(message = "优惠券ID不能为空", groups = {AddGroup.class, EditGroup.class})
    private Integer couponId;

    /**
     * 折扣金额/减免金额
     */
    private BigDecimal discountAmount;

    /**
     * 使用时间
     */
    private Date usageTime;

    /**
     * 用户ID
     */
    private Integer userId;

}
